<!DOCTYPE html>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@taglib uri="http://www.springframework.org/tags/form" prefix="form"%>
<%@taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<html>
	<head>
		<meta charset="utf-8">
		<title>Employee management : <spring:message code="employee.new" text="New Employee" var="newEmployee" /></title>
	</head> 
	<body>
		<header>
		<h1>${newEmployee}</h1>
			<nav>
				<%@include file="Employee.jsp" %>
			</nav>
		</header>

		<spring:url value="/employee/save" var="urlsave" />
		<form:form method="post" action="${urlsave}" commandName="employee">
		
		<div>
        	<form:label path="name"><spring:message code="employee.name" text="Name" /></form:label>
        	<form:errors path="name" />
        </div>
		
        <div>
        	<form:label path="birthdate"><spring:message code="employee.idstate" text="Birth" /></form:label>
        	<form:errors path="birthdate" />
        </div>
        <div><form:input path="birthdate" /></div> 

        <div><form:input path="name" /></div>

        <div>
        	<form:label path="phone"><spring:message code="employee.phone" text="Phone" /></form:label>
        	<form:errors path="phone" />
        </div>
        <div><form:input path="phone" /></div>
        
        <div>
            <input type="submit" value="${newEmployee}" />
        </div>
     
</form:form>
	</body>
</html>